﻿using System.Buffers;
using IOP.Net;
using System;

namespace IOP.Pulsar.Abstractions
{
    /// <summary>
    /// 管线入口接口
    /// </summary>
    /// <typeparam name="TContext">入口上下文</typeparam>
    public interface IProductLineEntry<TContext> : IDisposable
        where TContext : class
    {
        /// <summary>
        /// 管线
        /// </summary>
        ProductLineDelegate<TContext> ProductLine { get; set; }

        /// <summary>
        /// 入口处理函数
        /// </summary>
        void EntryHandle(ref ReadOnlySequence<byte> queue, SocketMonitor socket);
    }
}
